package com.carter.springframework.context.event;

import com.carter.springframework.context.ApplicationEvent;
import com.carter.springframework.context.ApplicationListener;

/**
 * spring事件广播器普通实现
 */
public class SimpleApplicationEventMulticaster extends AbstractApplicationEventMulticaster{
    @Override
    public void multicastEvent(ApplicationEvent event) {
        for (ApplicationListener<ApplicationEvent> listener : getApplicationListeners(event)) {
            listener.onApplicationEvent(event);
        }
    }
}
